local-CVE-2023-6246
authorGNU Libc Maintainers <debian-glibc@lists.debian.org>
Tue, 23 Jan 2024 20:57:06 +0000 (21:57 +0100)
committerAurelien Jarno <aurel32@debian.org>
Tue, 23 Jan 2024 20:57:06 +0000 (21:57 +0100)
commiteec73cdc3f318b79373e4158452348577c7214c2
tree5e2da0f8c2bf28f3a1ab2e672d8fb8a5230f0028
parent8f8f2926332996d8fa0a97fd722bfa935fdb98fb
local-CVE-2023-6246

syslog: Fix heap buffer overflow in __vsyslog_internal (CVE-2023-6246)

__vsyslog_internal did not handle a case where printing a SYSLOG_HEADER
containing a long program name failed to update the required buffer
size, leading to the allocation and overflow of a too-small buffer on
the heap.  This commit fixes that.  It also adds a new regression test
that uses glibc.malloc.check.

Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Gbp-Pq: Topic any
Gbp-Pq: Name local-CVE-2023-6246.patch
misc/Makefile
misc/syslog.c
misc/tst-syslog-long-progname.c [new file with mode: 0644]